﻿<!DOCTYPE html>
<html>
<head>
	<meta charset="UTF-8">
	<title>コントロールパネル</title>

    <link href="./assets/styles/default.css" rel="stylesheet" />
	<script src="./assets/scripts/libs/jquery-1.7.1.min.js" type="text/javascript"></script>
	<script src="./assets/scripts/import.js" type="text/javascript"></script>

	<style>
		.tLeft {
			clear: both;
			float:left;width:48%;
		}
		.tRight {
			float:right;width:48%;
		}
		h5 {
			padding:10px;
			margin: 0;
			text-align: left;
			background-color: #f5f5f5;
			border-bottom: 3px double #e5e5e5;
			font-size: 14px;
		}
		#totalTable th {
			text-align: right !important;
		}

	</style>
	<script type="text/javascript">
	    function check(tableid) {
	        var ret = true;
	        //checkempty
	        if (tableid == "t1" || tableid == "t2" || tableid == "t3" || tableid == "t4") {
	            $("#" + tableid + " input:text").each(
					function (i, el) {
					    if ($(this).val() == "") {
					        alert("入力してください");
					        $(this).focus(); ret = false; return false;
					    }
					}
			);
	        }
	        if (!ret) return ret;

	        //checknumbers
	        if (tableid == "t3" || tableid == "t4") {
	            $("#" + tableid + " input[chk='num']").each(
					function (i, el) {
					    if (!$.isNumeric($(this).val())) {
					        alert("半角整数で入力してください");
					        $(this).focus(); ret = false; return false;
					    }
					}
			);
	        }
	        if (!ret) return ret;
	        return ret
	    }

	    function isDate(value) {
	        var ereg = /^(\d{1,4})(-|\/)(\d{1,2})(-|\/)(\d{1,2}) {1,10}(0\d{1}|1\d{1}|2[0-3]):[0-5]\d{1}:([0-5]\d{1})$/;
	        var r = value.match(ereg);
	        if (r == null) {
	            return false;
	        }
	        var d = new Date(r[1], r[3] - 1, r[5]);
	        var result = (d.getFullYear() == r[1] && (d.getMonth() + 1) == r[3] && d.getDate() == r[5]);
	        return result;
	    }
	    $(function () {
	        $('#btn_update').unbind().click(function (e) {
	            if (!check('t2')) { return false; };
	            customConfirm('更新してよろしいですか？', "", $(this), function () {
	                loading();
	                //pushID();
	                //$('input[name=mode]', form).val('input');
	                $('form').submit();
	            });

	        });
	    });
	</script>
</head>
<body>

{{$zhead}}
<div id="container">
{{$zmenu}}

<center><span style="color:red;">{{$errmsg}}</span></center>
    <article>
    	<h2><span>&nbsp;</span>注文管理<p><a href="javascript:;">Open Plugins</a></p></h2>
        <nav>
        	<ul>
				<li class="active"><a href="Home_OrderManage_index.html"><span>履歴検索</span></a></li>
				<li><a href="Home_order_summary.html"><span>売上集計</span></a></li>
				<li><a href="Home_order_setting.html"><span>基本設定</span></a></li>
			</ul>
        </nav>
		<section id="content">
			<h3>注文情報参照</h3>
			<ul class="clear btns float-right t10 b10" style="position:relative;top: 5px;right: -15px;">
				<li class="btn single c"><a href="{{'Home/OrderRefer/index'|U}}?oid={{$orderrow.order_id}}" >戻る</a></li>
			</ul>
			<form name="fm" id="fm" action="{{'Home/OrderRefer/updatesendaddress'|U}}" method="post" enctype="multipart/form-data" class="clear">
			<input name="order_id" type="hidden" value="{{$orderrow.order_id}}">
				<h4>
					<span>&nbsp;</span>
					注文No.{{$orderrow.order_number}}
					&nbsp;&nbsp;
					{{$orderrow.order_time|date_format:"%Y/%m/%d %H:%M:%S"}}
				</h4>

				
					<h5>
						配送住所
						
					</h5>
					<table class="formTable" id="t2">
						<tbody>
							<tr>
								<th>氏名</th>
								<td>
								<input name="send_name1" type="text" value="{{$orderrow.send_name1}}">
								<input name="send_name2" type="text" value="{{$orderrow.send_name2}}">
								</td>
							</tr>
							<tr>
								<th>貴医院名・貴技工所名</th>
								<td><input name="send_office_name" type="text" value="{{$orderrow.send_office_name}}"></td>
							</tr>
							<tr>
								<th>住所</th>
								<td>
								<input name="send_local_name" type="text" value="{{$orderrow.send_local_name}}">
								<input name="send_treet_name" type="text" value="{{$orderrow.send_treet_name}}">
								<input name="send_address" type="text" value="{{$orderrow.send_address}}">
								</td>
							</tr>
							<tr>
								<th>電話番号</th>
								<td><input name="send_tel_number" type="text" value="{{$orderrow.send_tel_number}}"></td>
							</tr>
						</tbody>
					</table>
					

				<p class="button">
					<button type="button" id="btn_update" class="submit" ><span>更新</span></button>
				</p>
			</form>
		</section>
	</article>
</div>
<footer id="dashboard_footer">Copyright (C) SHIFT. / All rights reserved.</footer>
</body>
</html>